 int n=sc.nextInt();
	    Object []o=new Object[n];
	    String str;
	    for (int i = 0; i < n ;i++) {
			str=sc.next();
			if(str.equals("c")){
				o[i]=new Computer();
				
			}
			else if(str.equals("d")){
				double x=sc.nextDouble();
				o[i]=new Double(x);
				
			}
			else if(str.equals("i")){
				int y=sc.nextInt();
				o[i]=new Integer(y);
			}
			else if(str.equals("s")){
				String z=sc.next();
				o[i]=new String(z);
			
				
			}
			else{
				o[i]=null;
					
			}
		}
	    for (int i = o.length-1; i >=0; i--) {
	    	if(o[i]!=null){
			System.out.println(o[i]);
	    	}
		}